package com.tanhua.admin.controller;

import com.bilibili.model.vo.AnalysisSummaryVo;
import com.tanhua.admin.service.AnalysisService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author HuangRongFu
 * 2021/11/30 星期二3:17 下午
 */

@RestController
@RequestMapping("/dashboard")
public class DashboardController {

    @Autowired
    private AnalysisService analysisService;


    /**
     * 首页统计
     * @Return: ResponseEntity
     */
    @GetMapping("/summary")
    public ResponseEntity summary(){

        AnalysisSummaryVo vo = analysisService.summary();

        return ResponseEntity.ok(vo);
    }
}
